Arrow keys / Click to navigate

Module 10: Large-Scale Data Stores

Advanced Architecting on AWS

S3 Advanced โ€ข Lake Formation โ€ข Athena โ€ข Redshift โ€ข Data Lake

๐ŸŽฏ Module Objectives

๐Ÿ“ฆ S3 Advanced Features

FeaturePurposeDetails
Cross-Region ReplicationDR, compliance, latencyAsync replication. Can replicate to different account.
Same-Region ReplicationCompliance copies, log aggregationSame region, different bucket (even same account)
Object LockWORM complianceGovernance mode (admin bypass) or Compliance mode (immutable)
S3 Access PointsSimplified access managementNamed endpoints with unique policies. Per-app access.
S3 Intelligent-TieringAuto-tieringMoves objects between tiers based on access patterns

๐Ÿž๏ธ Data Lake Architecture

Data lake zones: Landing (raw) โ†’ Processing (cleaned/transformed) โ†’ Curated (business-ready). Lake Formation acts as the security guard controlling who accesses each zone.

๐Ÿ” Amazon Athena & Redshift Serverless

Amazon Athena

Serverless SQL on S3. Presto-based. Pay $5/TB scanned. Use columnar formats (Parquet/ORC) to reduce cost. Federated queries to RDS/DynamoDB.

Redshift Serverless

Data warehouse without cluster management. Auto-scales. Pay for compute (RPU-hours). Complex analytics, joins, aggregations at PB scale.

Decision: Ad-hoc queries on S3 data? โ†’ Athena. Complex analytics with dashboards, frequent queries, PB-scale joins? โ†’ Redshift Serverless.

๐ŸŒ DynamoDB Global Tables

Pattern: Global Tables + Route 53 latency routing = users always hit the nearest DynamoDB replica with full read/write capability. True active-active at the database layer.

๐Ÿ’ป Demo: S3 Replication & Athena

# Enable versioning (required for replication)
aws s3api put-bucket-versioning --bucket source-bucket \
  --versioning-configuration Status=Enabled

# Configure cross-region replication
aws s3api put-bucket-replication --bucket source-bucket \
  --replication-configuration file://replication.json

# Run an Athena query
aws athena start-query-execution \
  --query-string "SELECT * FROM logs WHERE date = '2025-01-15' LIMIT 100" \
  --work-group primary \
  --query-execution-context Database=analytics

๐Ÿงช Knowledge Check

Q1: A financial company must store audit logs in S3 that cannot be deleted or modified for 7 years, even by administrators. Which feature should they use?

A) S3 Versioning   B) Object Lock (Governance mode)   C) Object Lock (Compliance mode)   D) Bucket policy deny

C) Object Lock (Compliance mode) โ€” Compliance mode cannot be overridden by any user, including the root account. Objects are truly immutable for the retention period. Governance mode allows admin bypass.

Q2: A global e-commerce platform needs sub-second read/write latency for their product catalog in all regions. Which is the best solution?

A) RDS Multi-AZ   B) Aurora Global Database   C) DynamoDB Global Tables   D) ElastiCache Global Datastore

C) DynamoDB Global Tables โ€” Global Tables provide multi-region, multi-active read/write with sub-second replication. Users can write to the nearest region. Aurora Global allows reads in all regions but writes only in primary.

๐Ÿ“ Module 10 Summary

S3 Advanced

CRR/SRR replication. Object Lock (WORM). Access Points. Intelligent-Tiering. Lifecycle policies.

Data Lake

S3 foundation + Glue catalog + Lake Formation governance. Raw โ†’ Processed โ†’ Curated zones.

Analytics

Athena: serverless SQL on S3. Redshift Serverless: PB-scale warehouse. Use Parquet for cost savings.

Global Tables

DynamoDB multi-region active-active. Sub-second replication. Last-writer-wins conflict resolution.

Click anywhere to close